package com.ruoyi.system.mapper;

import com.ruoyi.system.domain.PracticeCadetExperience;
import com.ruoyi.system.domain.PracticeCadetExperienceCount;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 实践心得Mapper接口
 *
 * @author dp
 * @date 2023-11-27
 */
public interface PracticeCadetExperienceMapper {
    /**
     * 查询实践心得
     *
     * @param experienceId 实践心得主键
     * @return 实践心得
     */
    PracticeCadetExperience selectPracticeCadetExperienceByExperienceId(Long experienceId);

    /**
     * 查询实践心得列表
     *
     * @param practiceCadetExperience 实践心得
     * @return 实践心得集合
     */
    List<PracticeCadetExperience> selectPracticeCadetExperienceList(PracticeCadetExperience practiceCadetExperience);

    /**
     * 查询实践心得合计列表
     * @param submitBegin
     * @param submitEnd
     * @param baseId
     * @param experienceStatus
     * @return
     */
    List<PracticeCadetExperienceCount> selectPracticeCadetExperienceCount(@Param("submitBegin") String submitBegin,
                                                                          @Param("submitEnd") String submitEnd,
                                                                          @Param("baseId") String baseId,
                                                                          @Param("experienceStatus") String experienceStatus);

    /**
     * 根据条件查询实践心得
     * @param submitBegin
     * @param submitEnd
     * @param baseId
     * @param cadetId
     * @param experienceStatus
     * @return
     */
    List<PracticeCadetExperience> getExperienceList(@Param("submitBegin") String submitBegin,
                                                    @Param("submitEnd") String submitEnd,
                                                    @Param("baseId") String baseId,
                                                    @Param("cadetId") String cadetId,
                                                    @Param("experienceStatus") String experienceStatus);

    /**
     * 新增实践心得
     *
     * @param practiceCadetExperience 实践心得
     * @return 结果
     */
    int insertPracticeCadetExperience(PracticeCadetExperience practiceCadetExperience);

    /**
     * 修改实践心得
     *
     * @param practiceCadetExperience 实践心得
     * @return 结果
     */
    int updatePracticeCadetExperience(PracticeCadetExperience practiceCadetExperience);

    /**
     * 删除实践心得
     *
     * @param experienceId 实践心得主键
     * @return 结果
     */
    int deletePracticeCadetExperienceByExperienceId(Long experienceId);

    /**
     * 批量删除实践心得
     *
     * @param experienceIds 需要删除的数据主键集合
     * @return 结果
     */
    int deletePracticeCadetExperienceByExperienceIds(Long[] experienceIds);
}
